{assign var=showSitesSelection value=false}
{assign var=showPeriodSelection value=false}
{include file="CoreAdminHome/templates/header.tpl"}
{loadJavascriptTranslations plugins='LoginLdap'}

{literal}
<style type="text/css">
.dialog {
	display: none;
	padding:20px 10px;
	color:#7A0101;
	cursor:wait;
	font-size:1.2em;
	font-weight:bold;
	text-align:center;
}
.editable:hover, .addrow:hover, .updateAccess:hover, .accessGranted:hover, .adduser:hover, .edituser:hover, .deleteuser:hover, .updateuser:hover, .cancel:hover{
	cursor: pointer;
}
.addrow {
	font-color:#3A477B;
	padding:1em;
	font-weight:bold;
}
.addrow a {
	text-decoration: none;
}
.addrow img {
	vertical-align: middle;
}
</style>
{/literal}

{if $ajaxSuccess}
<div class="ajaxSuccess">{$ajaxSuccess}</div>
{/if}
{if $ajaxError}
<div class="ajaxError">{$ajaxError}</div>
{/if $ajaxError}

<h2>{'LoginLdap_LoadUser'|translate}</h2>
<div style="float:left">

<p>{'LoginLdap_LoadUserDescription'|translate}</p>

<table id='ldapLoadUserTable' class="adminTable" style="width:750px">
<form method="post" action="{url action=loadUser}" id="loadUserForm">

<tr>
    <td width="150"><label for="username">{'General_Username'|translate} </label></td>
    <td>
        <input size="25" value="" id="username" name="username" />
		<input class="submit" type="submit" value="{'LoginLdap_LoadUser'|translate}" />
	</td>
</tr>

</form>
</table>

</div>

<div style="float:right">
	<p style="padding:0; margin:0">{'LoginLdap_DevelopedBy'|translate}</p>
	<a target="_blank" href="http://www.gigatec.de/"><img src="plugins/LoginLdap/templates/images/logo_gigatec.png" /></a>
</div>


<h2>{'LoginLdap_Settings'|translate}</h2>

<table id='ldapSettingsTable' class="adminTable" style='width:900px'>
<form method="post" action="{url action=saveSettings}" id="saveSettingsForm">

<tr>
    <td width="150"><label for="serverUrl">{'LoginLdap_ServerUrl'|translate} </label></td>
    <td>
        <input size="25" value="{$config->serverUrl}" id="serverUrl" name="serverUrl" />
        <span class='form-description'>{'LoginLdap_ServerUrlDescription'|translate}</span>
    </td>
</tr>

<tr>
    <td><label for="baseDn">{'LoginLdap_BaseDn'|translate} </label></td>
    <td>
        <input size="25" value="{$config->baseDn}" id="baseDn" name="baseDn" />
        <span class='form-description'>{'LoginLdap_BaseDnDescription'|translate}</span>
    </td>
</tr>

<tr>
    <td><label for="userIdField">{'LoginLdap_UserIdField'|translate} </label></td>
    <td>
        <input size="25" value="{$config->userIdField}" id="userIdField" name="userIdField" />
        <span class='form-description'>{'LoginLdap_UserIdFieldDescription'|translate}</span>
    </td>
</tr>

<tr>
    <td><label for="mailField">{'LoginLdap_MailField'|translate} </label></td>
    <td>
        <input size="25" value="{$config->mailField}" id="mailField" name="mailField" />
        <span class='form-description'>{'LoginLdap_MailFieldDescription'|translate}</span>
    </td>
</tr>

<tr>
    <td><label for="aliasField">{'LoginLdap_AliasField'|translate} </label></td>
    <td>
        <input size="25" value="{$config->aliasField}" id="aliasField" name="aliasField" />
        <span class='form-description'>{'LoginLdap_AliasFieldDescription'|translate}</span>
    </td>
</tr>

<tr>
    <td><label for="aliasField">{'LoginLdap_UsernameSuffix'|translate} </label></td>
    <td>
        <input size="25" value="{$config->usernameSuffix}" id="usernameSuffix" name="usernameSuffix" />
        <span class='form-description'>{'LoginLdap_UsernameSuffixDescription'|translate}</span>
    </td>
</tr>

<tr>
    <td><label for="aliasField">{'LoginLdap_AdminUser'|translate} </label></td>
    <td>
        <input size="25" value="{$config->adminUser}" id="adminUser" name="adminUser" />
        <span class='form-description'>{'LoginLdap_AdminUserDescription'|translate}</span>
    </td>
</tr>

<tr>
    <td><label for="aliasField">{'LoginLdap_AdminPass'|translate} </label></td>
    <td>
        <input size="25" value="{$config->adminPass}" id="adminPass" name="adminPass" type="password" />
    </td>
</tr>

<tr>
    <td><label for="aliasField">{'LoginLdap_MemberOf'|translate} </label></td>
    <td>
        <input size="25" value="{$config->memberOf}" id="memberOf" name="memberOf" />
        <span class='form-description'>{'LoginLdap_MemberOfDescription'|translate}</span>
    </td>
</tr>

<tr>
	<td align="left">
		<input class="submit" type="submit" value="{'General_Save'|translate}" />
	</td>
	<td></td>
</tr>

</form>
</table>
        

{include file="CoreAdminHome/templates/footer.tpl"}
